package com.shisfish.english.transform.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Component;

import com.shisfish.english.dao.ISingleWordDao;
import com.shisfish.english.model.SingleWord;
import com.shisfish.english.transform.ISingleWordTransform;

@Component
public class SingleWordTransformImpl implements ISingleWordTransform {

	@Resource 
	private ISingleWordDao singleWordDao;
	
	@Override
	public int insertObj(SingleWord t) {
		return singleWordDao.insertObj(t);
	}

	@Override
	public int updateObj(SingleWord t) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public int deleteObj(SingleWord t) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public int deleteById(long id) {
		return singleWordDao.deleteById(id);
	}

	@Override
	public SingleWord selectById(long id) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public List<SingleWord> selectAll() {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public List<SingleWord> selectByNameL(String name) {
		return singleWordDao.selectByNameL(name);
	}

	@Override
	public int changeMeaning(long id, String meaning) {
		return singleWordDao.changeMeaning(id, meaning);
	}

	@Override
	public SingleWord selectByName(String name) {
		return singleWordDao.selectByName(name);
	}

	@Override
	public List<SingleWord> selectByParams(String name) {
		return singleWordDao.selectByParams(name);
	}

	@Override
	public List<SingleWord> pageByParams(int pageBeginIndex, int pageSize, String name) {
		return singleWordDao.pageByParams(pageBeginIndex, pageSize, name);
	}

	@Override
	public int countByParams(String name) {
		return singleWordDao.countByParams(name);
	}

}
